<!DOCTYPE html>
{% from tornado.options import options %}
<html>
  <head>
    <title>Wdb server web interface</title>
    <meta charset="utf-8">
    <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
    <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Roboto">
    <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Roboto+Mono">
    {% set material_version = '1.1.3' %}
    {% set type = globals().get('type_', 'debug') %}
    {% set scheme = {
      'pm':    'red-indigo',
      'shell': 'teal-orange',
      'debug': 'indigo-red'
    }[type] %}
    <link rel="stylesheet" href="{{ static_url('libs/material-design-lite/material.%s.min.css' % scheme) }}">

    <script defer src="{{ static_url('libs/material-design-lite/material.min.js') }}"></script>
    <script src="{{ static_url('javascripts/wdb/deps.min.js') }}"></script>
    <link href="{{ static_url('stylesheets/deps.min.css') }}" rel="stylesheet" type="text/css">

    {% from wdb_server import StyleHandler %}
    {% block css %}
    {% end %}
  </head>
  <body {% if options.debug %}data-debug="true"{% end %} data-type="{{ type }}">
    <section class="wdb" data-page="{{ handler.__class__.__name__}}">
      {% block main %}
      {% end %}
    </section>
    {% block script %}{% end %}
  </body>
</html>
